<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>水仙花数</title>
    <style>
    *{
        padding:0;
        margin:0;
    }
    #container{
        
        display: flex;
        justify-content: space-between;
    }
    #container>div{
        width:25%;
        text-align: center;
        background-color: gray;
        color:red;
        /* border:1px solid red; */
    }
    .d1{
        display: inline-block;
        width:80px;
    }
    </style>
</head>
<body>
    <div id="container">
    <?php
      for($i=100;$i<=999;$i++){
        $a=(int)($i/100);
        $b=(int)(($i-($a*100))/10);
        $c=($i%10);
        if(pow($a,3)+pow($b,3)+pow($c,3)!=$i){
            continue;
        }
    ?>
    <div><?=$i?></div>
    <?php
    }
    ?>
    </div>

<br>
<br>

    <div>
    <?php
    for($i=1;$i<=9;$i++){
    ?>
    <div>
    <?php
        for($j=1;$j<=$i;$j++){
        ?>
        
        <div class="d1"><?="${j}*${i}=".($i*$j)?></div>
        <?php  
        }
        ?>
   </div>
    <?php
    }
    ?>
    </div>
</body>
</html>


